﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Summary.master" AutoEventWireup="true"
    CodeFile="GradeScaleDetail.aspx.cs" Inherits="Grade_GradeScaleDetail" %>

<asp:Content ID="Content1" ContentPlaceHolderID="DetailHeaderContent" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="DetailBodyContent" runat="Server">
    <asp:UpdatePanel ID="uplGradeScale" runat="server">
        <ContentTemplate>
            <asp:GridView ID="gvGradeScaleDetail" runat="server" Width="550px" AutoGenerateColumns="false"
                CssClass="table" ShowFooter="true" OnPageIndexChanging="OnPaging" OnRowEditing="EditGradeScaleDetail"
                OnRowUpdating="UpdateGradeScaleDetail" OnRowCancelingEdit="CancelEdit" PageSize="10" OnRowDataBound="gvGradeScaleDetail_RowDataBound"
                OnRowCreated="gvGradeScaleDetail_RowCreated">
                <Columns>
                    <asp:TemplateField ItemStyle-Width="30px" HeaderText="GradeScaleID" Visible="false">
                        <ItemTemplate>
                            <asp:Label ID="lblGradeScaleDetailID" runat="server" Text='<%# Eval("GradeScaleDetailID")%>'></asp:Label>
                        </ItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox ID="txtGradeScaleDetailID" ReadOnly="true" Text="-1" Width="40px" MaxLength="5"
                                runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="Title">
                        <ItemTemplate>
                            <asp:Label ID="lblTitle" runat="server" Text='<%# Eval("Title")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtTitle" runat="server" Text='<%# Eval("Title")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtTitle" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="BreakOff">
                        <ItemTemplate>
                            <asp:Label ID="lblBreakOff" runat="server" Text='<%# Eval("BreakOff")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtBreakOff" runat="server" Text='<%# Eval("BreakOff")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtBreakOff" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="Weighted GPA">
                        <ItemTemplate>
                            <asp:Label ID="lblWeightedGPA" runat="server" Text='<%# Eval("WeightedGPA")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtWeightedGPA" runat="server" Text='<%# Eval("WeightedGPA")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtWeightedGPA" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="UnWeighted GPA">
                        <ItemTemplate>
                            <asp:Label ID="lblUnWeightedGPA" runat="server" Text='<%# Eval("UnWeightedGPA")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtUnWeightedGPA" runat="server" Text='<%# Eval("UnWeightedGPA")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtUnWeightedGPA" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="Order">
                        <ItemTemplate>
                            <asp:Label ID="lblSortOrder" runat="server" Text='<%# Eval("SortOrder")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtSortOrder" runat="server" Text='<%# Eval("SortOrder")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtSortOrder" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="Comments">
                        <ItemTemplate>
                            <asp:Label ID="lblComment" runat="server" Text='<%# Eval("Comment")%>'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:TextBox Width="90px" ID="txtComment" runat="server" Text='<%# Eval("Comment")%>'></asp:TextBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:TextBox Width="90px" ID="txtComment" runat="server"></asp:TextBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField ItemStyle-Width="90px" HeaderText="Active">
                        <ItemTemplate>
                            <asp:Label ID="lblActive" runat="server" Text='N/A'></asp:Label>
                        </ItemTemplate>
                        <EditItemTemplate>
                            <asp:CheckBox ID="chkActive" runat="server" Text=''></asp:CheckBox>
                        </EditItemTemplate>
                        <FooterTemplate>
                            <asp:CheckBox ID="chkActive" runat="server" Text=''></asp:CheckBox>
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:TemplateField>
                        <ItemTemplate>
                            <asp:LinkButton ID="lnkRemove" runat="server" CommandArgument='<%# Eval("GradeScaleDetailID")%>'
                                OnClientClick="return confirm('Do you want to delete?')" Text="Delete" OnClick="DeleteGradeScaleDetail"></asp:LinkButton>
                        </ItemTemplate>
                        <FooterTemplate>
                            <asp:Button ID="btnAdd" runat="server" Text="Add" OnClick="AddGradeScaleDetail" />
                        </FooterTemplate>
                    </asp:TemplateField>
                    <asp:CommandField ShowEditButton="True" />
                </Columns>
                <AlternatingRowStyle CssClass="alt" />
            </asp:GridView>
        </ContentTemplate>
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="gvGradeScaleDetail" />
        </Triggers>
    </asp:UpdatePanel>
</asp:Content>
